-
Notifications
You must be signed in to change notification settings - Fork 529
fix: minimize CCTP bytecode size #7265
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## audit-q3-2025 #7265 +/- ##
==================================================
+ Coverage 0.00% 76.69% +76.69%
==================================================
Files 1 123 +122
Lines 14 2712 +2698
Branches 0 252 +252
==================================================
+ Hits 0 2080 +2080
- Misses 14 614 +600
- Partials 0 18 +18
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Damn, how complex is the contract? Where is the meat of it?
What claude thinks: ⏺ Based on my analysis, the majority of the bytecode size in the CCTP contracts comes from: Main Contributors to Bytecode Size
TokenBridgeCctpBase inherits from three base contracts:
The verify() function in TokenBridgeCctpBase.sol:249-288 contains:
|
|
noting that the storage incompatibility is only against unreleased version |
|
Caution Review failedThe pull request is closed. 📝 WalkthroughWalkthroughThis change peels back layers of abstraction by inlining TokenBridgeCctpBase and removing AbstractMessageIdAuthorizedIsm coupling. It introduces direct domain mappings, replaces message-based verification with messageId-based tracking, and adds sender authorization checks at the _receiveMessageId level instead of through inheritance hooks. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Areas requiring extra attention:
Possibly related PRs
Suggested reviewers
Poem
✨ Finishing touches🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (2)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Description
Removes inheritance from
AbstractMessageIdAuthorizedIsmto get under maximum bytecode sizeError: some contracts exceed the runtime size limit (EIP-170: 24576 bytes)Backward compatibility
Yes
Testing
Unit Tests
Summary by CodeRabbit
Refactor
Bug Fixes